package com.example.leepong.Game.Shapes;

/**
 * Created by Ichigo on 28/02/14.
 */
public class FixedRectangle {
    public float X;
    public float Y;
    public int Width;
    public int Height;
    public float Left;
    public float Top;
    public float Right;
    public float Bottom;
    public float CenterX;
    public float CenterY;

    private Rectangle rect;

    public FixedRectangle(Rectangle rect) {
        this.rect = rect;
        this.X = rect.Coord.X;
        this.Y = rect.Coord.Y;
        this.Width = rect.Width;
        this.Height = rect.Height;
        this.Left = rect.Left();
        this.Right = rect.Right();
        this.Top = rect.Top();
        this.Bottom = rect.Bottom();
        this.CenterX = rect.CenterX();
        this.CenterY = rect.CenterY();
    }

    public boolean Contains(Coordinates coord) {
        return this.Contains(coord.X, coord.Y);
    }

    public boolean Contains(float x, float y) {
        return this.rect.Contains(x, y);
    }

}
